package kz.edu.sdu.atm.client;

import java.io.PrintWriter;
import java.util.Scanner;

import kz.edu.sdu.atm.models.Request;
import kz.edu.sdu.atm.models.Response;
import kz.edu.sdu.atm.server.IServer;

public abstract class IComProtocolClient {
	Scanner in;
	PrintWriter out;
	IServer server;

	public abstract Response getResopnse(Scanner in);

	public abstract void sendRequest(PrintWriter out, Request req);

	public Response speak(Request req) {
		sendRequest(out, req);
		Response res = getResopnse(in);
		return res;
	}
}
